package com.ruoyi.system.service.impl;

import com.ruoyi.common.core.constant.CacheNames;
import com.ruoyi.system.domain.SysApplication;
import com.ruoyi.system.mapper.SysApplicationMapper;
import com.ruoyi.system.service.ISysApplicationService;
import lombok.AllArgsConstructor;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.stereotype.Service;

/**
 * @author lixbin
 * @ClassName SysApplicationServiceImpl
 * @description: TODO
 * @datetime 2024年 12月 29日 18:01
 * @version: 1.0
 */
@Service
@AllArgsConstructor
public class SysApplicationServiceImpl implements ISysApplicationService {
    private final SysApplicationMapper applicationMapper;
    @Override
    @Cacheable(cacheNames = CacheNames.SYS_APPLICATION, key = "#secret")
    public SysApplication getBySecret(String secret) {
        return applicationMapper.getBySecret(secret);
    }
}
